﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using ThanhTu.GNC.Media.KQXS.DataAccess.DAL;
using System.Data;
using ThanhTu.GNC.Media.KQXS.DataAccess.DO;

namespace ThanhTu.GNC.Media.KQXS.DataAccess.BL
{
    public class CalendarBL : IDisposable
    {
        private CalendarDAL vCalendarDAL = null;
        private bool disposed = false;
        public CalendarBL()
        {
            if (vCalendarDAL == null)
            {
                vCalendarDAL = new CalendarDAL();
            }
        }
        ~CalendarBL() { Dispose(false); }

        #region IDisposable Members

        public void Dispose()
        {
            Dispose(true);
            GC.SuppressFinalize(this);
        }

        private void Dispose(bool disposing)
        {
            if (!disposed)
            {
                if (disposing)
                {
                    if (vCalendarDAL != null)
                    {
                        vCalendarDAL.Dispose();
                        vCalendarDAL = null;
                    }
                }

                disposed = true;
            }
        }

        #endregion

        public List<CalendarDO> SelectAll_Calendar() { return vCalendarDAL.SelectAll_Calendar(); }
    }
}
